Stage = function(options){
	var _options = {};
	$.extend(_options,this._options,options);
	$.extend(this,{
		_options:_options
	});
	this._init();
};
Stage.prototype = {
		_options:{
			width:"100%",
			height:"100%"
		},
		_stage:null,
		_units:[],
		_timer:null,
		_init:function(){
			this._stage = document.createElement("div");
			this._stage.style.width = Utils.pixel.style(this._options.width);
			this._stage.style.height = Utils.pixel.style(this._options.height);
			this._stage.style.background = "#f2f2f2";
			this._stage.style.border = "1px solid #333";
			this._stage.style.position = "absolute";
			this._stage.style.top = "0px";
			this._stage.style.left = "0px";			
			
			this._timer = new Timer($.proxy(this._onTick,this),10);
			
			document.body.appendChild(this._stage);
			
			this._timer.start();
		},
		addElement:function(unit){
			var adapter = new UnitAdapter({
				dom:unit.dom(),
				velocity:Math.ceil(Math.random()*10)*0,
				a:0,
				direction:Math.ceil(Math.random()*90)
			});
			this._units.push(adapter);
			this._stage.appendChild(unit.dom());
		},
		_onTick:function(timer){
			for(var i=0;i<this._units.length;i++){
				this._units[i].move();
			}
		}
};